package com.tony.blog.server.service.web;

import com.tony.blog.model.request.IdRequest;
import com.tony.blog.model.request.UserRequest;
import org.springframework.web.multipart.MultipartHttpServletRequest;

import java.io.IOException;
import java.util.Map;

/**
 * Created with IntelliJ IDEA.
 *
 * @Title: IndexUserService
 * @Auther: 皮蛋布丁
 * @Date: 2021/08/18/21:38
 * @Description: 前端用户
 */
public interface IndexUserService {

    /**
    * @Description: registerUser 注册用户
    * @Param: [userRequest]
    * @return: java.lang.Boolean
    * @Author: 皮蛋布丁
    * @Date: 2021/8/18 21:53
    */
    Boolean registerUser(UserRequest userRequest);

    /**
    * @Description: getUserMsg 获取用户消息
    * @Param: [userId]
    * @return: java.util.Map<java.lang.String,java.lang.Object>
    * @Author: 皮蛋布丁
    * @Date: 2021/8/19 20:48
    */
    Map<String,Object> getUserMsg(int userId);

    /**
    * @Description: uploadImg 上传用户头像
    * @Param: [request, userId]
    * @return: java.lang.String
    * @Author: 皮蛋布丁
    * @Date: 2021/8/21 21:55
    */
    String uploadImg(MultipartHttpServletRequest request, Long userId) throws IOException, Exception;

    /**
    * @Description: readMsg 读消息
    * @Param: [request, userId]
    * @return: java.lang.Boolean
    * @Author: 皮蛋布丁
    * @Date: 2021/9/26 21:35
    */
    Boolean readMsg(IdRequest request, Long userId);
}
